	.arch armv8-a
	.file	"main.c"
	.text
	.section	.text.startup,"ax",@progbits
	.align	2
	.p2align 3,,7
	.global	main
	.type	main, %function
main:
	stp	x29, x30, [sp, -112]!
	mov	w2, 10
	add	x29, sp, 0
	stp	x19, x20, [sp, 16]
	mov	x20, x1
	stp	x21, x22, [sp, 32]
	mov	x1, 0
	ldr	x0, [x20, 8]
	str	x23, [sp, 48]
	bl	strtol
	mov	x19, x0
	ldr	x0, [x20, 16]
	mov	w2, 10
	mov	x1, 0
	bl	strtol
	mov	x21, x0
	add	w0, w19, 8
	mov	w22, w21
	sxtw	x0, w0
	lsl	x20, x0, 3
	lsl	x0, x0, 4
	bl	malloc
	mov	x23, x0
	mov	w0, 100
	bl	srand
	cmn	w19, #7
	blt	.L2
	stp	x24, x25, [x29, 56]
	add	w24, w19, 7
	add	x24, x24, 1
	add	x25, x23, x20
	lsl	x24, x24, 3
	str	x26, [x29, 72]
	mov	x26, 0
	.p2align 2
.L3:
	bl	rand
	negs	w1, w0
	and	w2, w0, 1023
	and	w0, w1, 1023
	csneg	w0, w2, w0, mi
	scvtf	d0, w0
	str	d0, [x23, x26]
	str	d0, [x25, x26]
	add	x26, x26, 8
	cmp	x26, x24
	bne	.L3
	ldp	x24, x25, [x29, 56]
	ldr	x26, [x29, 72]
.L2:
	mov	x1, 0
	add	x0, x29, 80
	bl	gettimeofday
	cmp	w21, 0
	ble	.L4
	add	w13, w19, 3
	cmp	w13, 3
	ble	.L4
	fmov	v4.2d, 2.0e+0
	sub	w10, w19, #1
	fmov	v3.2d, 2.5e-1
	mov	x14, 32
	mov	w9, w19
	add	x14, x14, x10, uxtw 3
	fmov	d6, 2.0e+0
	fmov	d5, 2.5e-1
	mov	w1, 0
	mov	w12, 1
	mov	w11, 2
	.p2align 2
.L6:
	add	w8, w1, 1
	and	x1, x1, 1
	and	x4, x8, 1
	mul	x1, x1, x20
	mul	x17, x4, x20
	add	x4, x1, 24
	add	x0, x1, 56
	add	x3, x17, 48
	add	x2, x17, 32
	cmp	x4, x3
	add	x6, x23, x1
	ccmp	x2, x0, 0, lt
	add	x7, x23, x17
	ccmp	w9, 5, 0, ge
	bls	.L25
	add	x3, x1, 40
	add	x3, x23, x3
	ubfx	w3, w3, 3, 1
	cmp	w3, 0
	csel	w0, w12, w11, eq
	cmp	w0, w10
	bhi	.L15
	mov	w15, 4
	cbz	w3, .L8
	ldp	d1, d0, [x6, 24]
	mov	w15, 5
	ldr	d2, [x6, 40]
	fmadd	d0, d0, d6, d2
	fadd	d0, d0, d1
	fmul	d0, d0, d5
	str	d0, [x7, 32]
.L8:
	uxtw	x2, w3
	sub	w3, w9, w3
	add	x2, x2, 5
	lsr	w16, w3, 1
	lsl	x2, x2, 3
	mov	x0, 0
	sub	x4, x2, #8
	sub	x5, x2, #16
	add	x18, x4, x1
	add	x2, x1, x2
	add	x4, x4, x17
	add	x1, x5, x1
	add	x2, x23, x2
	add	x17, x23, x18
	add	x4, x23, x4
	add	x5, x23, x1
	mov	w1, 0
	.p2align 2
.L9:
	ldr	q2, [x17, x0]
	add	w1, w1, 1
	ldr	q0, [x2, x0]
	cmp	w16, w1
	ldr	q1, [x5, x0]
	fmla	v0.2d, v2.2d, v4.2d
	fadd	v0.2d, v0.2d, v1.2d
	fmul	v0.2d, v0.2d, v3.2d
	str	q0, [x4, x0]
	add	x0, x0, 16
	bhi	.L9
	and	w1, w3, -2
	add	w0, w1, w15
	cmp	w3, w1
	beq	.L12
.L7:
	sxtw	x1, w0
	add	w0, w0, 1
	add	x2, x6, x1, lsl 3
	cmp	w13, w0
	ldr	d0, [x6, x1, lsl 3]
	ldr	d2, [x2, 8]
	ldr	d1, [x2, -8]
	fmadd	d0, d0, d6, d2
	fadd	d0, d0, d1
	fmul	d0, d0, d5
	str	d0, [x7, x1, lsl 3]
	blt	.L12
	sxtw	x0, w0
	add	x1, x6, x0, lsl 3
	ldr	d0, [x6, x0, lsl 3]
	ldr	d2, [x1, 8]
	ldr	d1, [x1, -8]
	fmadd	d0, d0, d6, d2
	fadd	d0, d0, d1
	fmul	d0, d0, d5
	str	d0, [x7, x0, lsl 3]
.L12:
	mov	w1, w8
	cmp	w22, w8
	bne	.L6
.L4:
	mov	x1, 0
	add	x0, x29, 96
	bl	gettimeofday
	ldp	x3, x4, [x29, 80]
	adrp	x2, .LC0
	ldp	x1, x0, [x29, 96]
	scvtf	d3, w21
	ldr	d5, [x2, #:lo12:.LC0]
	scvtf	d1, w19
	sub	x0, x0, x4
	sub	x1, x1, x3
	adrp	x2, .LC1
	scvtf	d2, x1
	scvtf	d0, x0
	fmul	d1, d1, d3
	ldr	d4, [x2, #:lo12:.LC1]
	adrp	x0, .LC2
	add	x0, x0, :lo12:.LC2
	fmadd	d0, d0, d5, d2
	fdiv	d0, d1, d0
	fdiv	d0, d0, d4
	bl	printf
	ldr	x23, [sp, 48]
	ldp	x19, x20, [sp, 16]
	mov	w0, 0
	ldp	x21, x22, [sp, 32]
	ldp	x29, x30, [sp], 112
	ret
	.p2align 3
.L25:
	add	x0, x6, 24
	add	x7, x7, 32
	add	x6, x6, x14
	.p2align 2
.L11:
	ldp	d0, d2, [x0, 8]
	ldr	d1, [x0], 8
	fmadd	d0, d0, d6, d2
	cmp	x0, x6
	fadd	d0, d0, d1
	fmul	d0, d0, d5
	str	d0, [x7], 8
	bne	.L11
	b	.L12
.L15:
	mov	w0, 4
	b	.L7
	.size	main, .-main
	.section	.rodata.cst8,"aM",@progbits,8
	.align	3
.LC0:
	.word	2696277389
	.word	1051772663
	.align	3
.LC1:
	.word	0
	.word	1104006501
	.section	.text.startup
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align	3
.LC2:
	.string	"GStencil/s = %f\n"
	.ident	"GCC: (GNU) 7.5.0"
	.section	.note.GNU-stack,"",@progbits
